package com.dowson.config;

import com.dowson.bean.Person;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;

/**
 * @Author Zoe
 * @Date: 2020/11/22
 * @Description
 */


// 指定外部配置文件路径
@PropertySource("classpath:person.properties")
@Configuration
@ComponentScan("com.dowson")
public class MainConfigOfProperties {
    @Bean
    public Person person(){
        return new Person();
    }
}
